package com.syyo.gulimall.seckill.config.rabbit;

import org.springframework.amqp.support.converter.Jackson2JsonMessageConverter;
import org.springframework.amqp.support.converter.MessageConverter;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @ author: wang
 * @ date: 2021/4/22 11:29
 * @ Description: 消息确认的回调配置
 */
@Configuration
public class MyRabbitConfig {


    /**
     * 发送的消息使用json格式
     *
     * @return
     */
    @Bean
    public MessageConverter messageConverter() {
        return new Jackson2JsonMessageConverter();
    }

}
